<?php

$installer = $this;

$installer->startSetup();

$installer->run("
DROP TABLE IF EXISTS `ves_vendor_warehouse`;
CREATE TABLE `ves_vendor_warehouse` (
  `entity_id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `vendor_id` varchar(11) NOT NULL DEFAULT '',
  `sender_name` varchar(50) NOT NULL DEFAULT '',
  `sender_zip_code` varchar(20) NOT NULL DEFAULT '',
  `status` smallint(2) NOT NULL DEFAULT '0',
  `number` smallint(3) unsigned zerofill DEFAULT NULL,
  PRIMARY KEY (`entity_id`)
) ENGINE=InnoDB AUTO_INCREMENT=0 DEFAULT CHARSET=utf8;
    
        
DROP TABLE IF EXISTS `ves_vendor_warehouse_details`;
CREATE TABLE `ves_vendor_warehouse_details` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `wid` int(11) unsigned NOT NULL COMMENT '仓库标识ID',
  `sender_phone` varchar(30) NOT NULL DEFAULT '' COMMENT '联系电话',
  `sender_country` varchar(30) NOT NULL DEFAULT '' COMMENT '国家',
  `sender_province` varchar(30) NOT NULL COMMENT '省份ID`',
  `sender_city` varchar(30) NOT NULL DEFAULT '' COMMENT '城市',
  `sender_postcode`  int(11) unsigned NOT NULL  COMMENT '仓库所在地邮编',     
  `sender_address` varchar(200) NOT NULL DEFAULT '' COMMENT '仓库详情地址',
  `sender_contact` varchar(30) NOT NULL DEFAULT '' COMMENT '仓库负责人',
  `sender_company` varchar(100) NOT NULL DEFAULT '' COMMENT '发货人公司',
  `sender_email` varchar(50) NOT NULL DEFAULT '' COMMENT '邮箱',
  `created_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `update_time` datetime NOT NULL COMMENT '修改时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=0 DEFAULT CHARSET=utf8;
    
");
$installer->endSetup(); 